package cn.com.cfae.iras.doc.analyze.parse.model.iaad;

import cn.com.cfae.iras.doc.analyze.parse.model.ExtractItem;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

import static cn.com.cfae.iras.doc.analyze.parse.model.BizBaseModel.SYNONYM_SPLIT_CHAR;

/**
 * Created by 佟媛媛 on 18/11/5.
 * 房地产行业
 */
public class FDCModel {



    public static String MODEL_NAME = "FDC";

    /**
     * 近一年销售金额
     */
    private static String XSJE = "XSJE";

    /**
     * 存货
     */
    private static String CH = "CH";

    /**
     * 预收账款
     */
    private static String YSZK = "YSZK";

    /**
     * 一二线城市待售面积占比
     */
    private static String DSMJZB = "DSMJZB";

    /**
     * 土地储备规划建筑面积
     */
    private static String GHJZMJ = "GHJZMJ";

    /**
     * 当年签约销售面积
     */
    private static String QYXSMJ = "QYXSMJ";

    /**
     * 是否出具非标准审计意见
     */
    private static String SJYJ = "SJYJ";

    /**
     * 毛利率
     */
    private static String MLL = "MLL";

    /**
     * 经营性净现金流
     */
    private static String XJL = "XJL";

    /**
     * 总负债
     */
    private static String ZFZ = "ZFZ";

    /**
     * 总资产
     */
    private static String ZZC = "ZZC";

    /**
     * 流动负债
     */
    private static String LDFZ = "LDFZ";

    /**
     * 货币资金、可供出售金融资产、应收票据
     */
    private static String YSPJ = "YSPJ";

    /**
     * 投资性房地产
     */
    private static String TZXFDC = "TZXFDC";

    /**
     * 主营业务收入
     */
    private static String ZYYWSR = "ZYYWSR";

    /**
     * 平均存货
     */
    private static String PJCH = "PJCH";


    /**
     * 营业收入
     */
    private static String YYSR = "YYSR";

    /**
     * 营业成本
     */
    private static String YYCB = "YYCB";

    private static Map<String, String> items = new HashMap<>();

    static {
        items.put(DSMJZB, "拓展面积占比|一二线城市待售面积占比|土地储备占比");
        items.put(XSJE, "签约销售金额|销售金额|商品房销售金额|协议销售金额");
        items.put(GHJZMJ,"土地储备规划建筑面积|土地储备面积|规划建筑面积|土地储备占地面积");
        items.put(QYXSMJ,"签约销售面积|销售面积");
    }

    public static List<ExtractItem> createExtractItemList() {
        List<ExtractItem> extractItemList = new ArrayList<>();
        items.forEach((key, value) -> {
            ExtractItem extractItem = new ExtractItem();
            extractItem = new ExtractItem();
            extractItem.setItemName(key);
            extractItem.setSynonyms(value.split(SYNONYM_SPLIT_CHAR));
            extractItemList.add(extractItem);
        });
        return extractItemList;
    }

}
